export function set_currentUser (currentUser) {
  !window._vm || !window._vm.$store || window._vm.$store.commit('message/set_currentUser', currentUser)
}

export function getConversationList () {
  return window._vm.$store.state.message.conversationList
}

export function set_currentConversation (conversation) {
  window._vm.$store.commit('message/set_currentConversation', conversation)
}

export function getNextReqMessageID () {
  return window._vm.$store.state.message.nextReqMessageID
}

export function getCurrentMessageList () {
  return window._vm.$store.state.message.currentMessageList
}

export function commit_set_currentMessageList (messageList) {
  window._vm.$store.commit('message/set_currentMessageList', messageList)
}

export function loadMoreMessageListByConversation (conversation) {
  return window._vm.$store.dispatch('message/loadMoreStore', conversation)
}
export function actions_loadMoreStore (conversation) {
  return window._vm.$store.dispatch('message/loadMoreStore', conversation)
}

export function commit_set_currentConversation (conversation) {
  window._vm.$store.commit('message/set_currentConversation', conversation)
}

export function getMessageState () {
  return window._vm.$store.state.message
}

export function getMessageStateCurrentConversation () {
  return getMessageState().currentConversation
}

export function dispatch_load_messageList_by_conversation (conversation) {
  return window._vm.$store.dispatch('message/loadMoreStore', conversation)
}
